package cn.fql.ymcc.feignclient;

import cn.fql.ymcc.domain.Login;
import cn.fql.ymcc.query.LoginQuery;
import cn.fql.ymcc.result.JSONResult;
import feign.hystrix.FallbackFactory;
import org.springframework.stereotype.Component;

@Component
public class LoginFallback implements FallbackFactory<ILoginFeignClient> {
    @Override
    public ILoginFeignClient create(Throwable throwable) {
        return new ILoginFeignClient() {
            @Override
            public JSONResult saveOrUpdate(Login login) {
                return null;
            }

            @Override
            public JSONResult delete(Long id) {
                return null;
            }

            @Override
            public JSONResult get(Long id) {
                return null;
            }

            @Override
            public JSONResult list() {
                return null;
            }

            @Override
            public JSONResult page(LoginQuery query) {
                return null;
            }

            @Override
            public Login getOneByUsername(String username) {
                return null;
            }
        };
    }
}
